const teacherObj = require('../modules/Teacher');

let TeacherController = {
    get_info: async function(req, res){
        let resultDate = await teacherObj.getInfo();
        res.send(resultDate);
    },
    post_addTeacher: async function(req,res){
        let data = req.body;
        let resultDate = await teacherObj.addTeacher(data);
        res.send(resultDate);
    },
    post_removeTeacher: async function(req,res){
        let data = req.body;
        let resultDate = await teacherObj.removeTeacher(data);
        res.send(resultDate);
    },
    post_setTeacher: async function(req,res){
        let data = req.body;
        let resultDate = await teacherObj.setTeacher(data);
        res.send(resultDate);
    }
}
module.exports = TeacherController;